# COMP3130 MAKEFILE
# Stephen Gould <stephen.gould@anu.edu.au>

FILES_H = board.h comms.h AI.h gameState.h evaluator.h globalData.h
FILES_CPP = board.cpp comms.cpp AI.cpp gameState.cpp evaluator.cpp globalData.cpp

FILES_OBJ = $(FILES_CPP:.cpp=.o)

CCC = g++

all: client server learner

server: ${FILES_OBJ} server.o
	${CCC} -g -o server server.o ${FILES_OBJ}

client: ${FILES_OBJ} client.o
	${CCC} -g -o client client.o ${FILES_OBJ}
	
learner: ${FILES_OBJ} learner.o
	${CCC} -g -o learner learner.o ${FILES_OBJ}
	
profiler: ${FILES_CPP} 
	${CCC} -o profiler learner.cpp ${FILES_CPP} -g -pg

%.o : %.cpp
	${CCC} -c $< -o $@

clean:
	rm -f client server learner profiler
	rm -f *.o
